package com.kabigon.jvm.heap;

/**
 * @author xu.biao
 * @version v1.0
 * @Package com.kabigon.jvm.heap
 * @data 2023/2/18 1:18
 */
public class Demo1_4 {
    public static void main(String[] args) throws InterruptedException {
        System.out.println("1...");
        Thread.sleep(30000);
        byte[] bytes = new byte[1024 * 1024 * 10]; // 10 mb
        System.out.println("2...");
        Thread.sleep(20000);
        bytes = null;
        System.gc();
        System.out.println("3...");
        Thread.sleep(1000000L);
    }
}
